#include <iostream>
#include <map>

using namespace std;

int main()
{
	multimap<int, int, greater<>> m{
		{1, 2},{2, 2},{2, 3},{2, 3},{4, 2},{5, 2},
	};
	auto pt = [&]()
	{
		for (auto pr : m)
			cout << "[" << pr.first << "]" << pr.second << " ";

		cout << endl;
	};

	pt();
	m.erase(m.lower_bound(2), m.end());
	pt();

	return 0;
}